Skip to content

fix(studio): retire legacy Style and Grade sections from flat inspector#2126

Open
vanceingalls wants to merge 1 commit into
studio-flat-06-pinning-multifieldfrom
studio-flat-07-retire-legacy-style-grade
Open

fix(studio): retire legacy Style and Grade sections from flat inspector#2126
vanceingalls wants to merge 1 commit into
studio-flat-06-pinning-multifieldfrom
studio-flat-07-retire-legacy-style-grade

Conversation

@vanceingalls

@vanceingalls vanceingalls commented Jul 10, 2026

Copy link
Copy Markdown
Collaborator

What

Seventh PR in the flat inspector stack (see #2120 for the foundation and full stack list). Removes the legacy ColorGradingSection/StyleSections render call sites from PropertyPanelFlat.tsx — with the flag on, these were rendering a second time below their flat equivalents (Color grading, Radius, Stroke, Effects, Clip, Transparency, Fill all doubled).

Stack: #2120#2121#2122#2123#2124#2125#2126 (this).

Why

This was flagged as an Important (non-blocking) finding in the final whole-branch review, then confirmed live during manual testing of #2125 — every Style/Grade control was visibly duplicated. Flat coverage was already confirmed complete for both groups, so the legacy twins were pure redundant duplication, not a fallback for missing functionality.

How

  • Removed the <ColorGradingSection> and <StyleSections hideFlex> blocks (and their now-dead imports) from PropertyPanelFlat.tsx only.
  • The legacy components themselves (propertyPanelColorGradingSection.tsx, propertyPanelStyleSections.tsx) are untouched — the non-flat legacy PropertyPanel.tsx still uses them when the feature flag is off.
  • As a side effect, useColorGradingController now runs exactly once per render instead of twice (the second invocation was inside the now-removed legacy ColorGradingSection instance) — resolving another Important finding from the whole-branch review.

Test plan

  • New test asserting the legacy sections' specific DOM shape (data-panel-section attribute) is absent with the flag on, scoped carefully to avoid a false failure against the flat Style group's own "Fill" row label (which is supposed to still render).
  • Confirmed the flag-off (legacy) panel's own tests are untouched — this PR only affects the flat path.
  • Full monorepo suite green (1563 tests, 0 failures); oxlint/oxfmt/fallow clean.
  • Unit tests added/updated
  • Manual testing performed (this is what surfaced the bug)
  • Documentation updated (not applicable — internal Studio UI behind an off-by-default flag)

vanceingalls commented Jul 10, 2026

Copy link
Copy Markdown
Collaborator Author

@miga-heygen miga-heygen left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed as part of the 15-PR edit-panel redesign stack. Full stack review posted on #2120. No blockers on this PR. — Miga

The flat inspector rendered its new Style/Grade groups AND the legacy
ColorGradingSection/StyleSections components a second time below them,
visibly doubling every control. Remove the now-redundant legacy render
call sites (and their now-unused imports) from PropertyPanelFlat.tsx;
those components stay intact for the legacy (flag-off) PropertyPanel.

@miguel-heygen miguel-heygen left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Final current-head pass: cabe45e. Reviewed the stack boundaries and current diff against the flat-inspector contracts; required checks have no failures/pending checks and no unresolved review threads remain. No new drift found; residual notes are non-blocking.

@vanceingalls vanceingalls force-pushed the studio-flat-07-retire-legacy-style-grade branch from cabe45e to 40487ac Compare July 11, 2026 01:34
@vanceingalls vanceingalls force-pushed the studio-flat-06-pinning-multifield branch from f3389dc to 45a06a5 Compare July 11, 2026 01:34

@miguel-heygen miguel-heygen left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Superseding earlier approval: the latest max-review pass found confirmed correctness issues in this flat-inspector stack (identity/selector-index state, hide-all write races, timing inference, slider pointer/keyboard/reset semantics, and duplicate React keys). Hold merge and require fixes plus re-review on the current stack head.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants